home *** CD-ROM | disk | FTP | other *** search
/ FishMarket 1.0 / FishMarket v1.0.iso / fishies / 351-375 / disk_374 / mat / paths < prev    next >
Text File  |  1992-05-06  |  689b  |  18 lines

  1. .K dest
  2. .BRA {
  3. .KET }
  4. ;;    PATHS     --  Preserves current path in a re-executable script.
  5.  
  6. run path >PIPE:s_path
  7. mat >{dest$re-path} P "~(C:|Current directory)" T "path ^O" label "failat 25^Bpath reset" PIPE:s_path label "failat 10"
  8. protect {dest$re-path} +S
  9.  
  10. ;; The output of the PATH command is PIPEd into Mat, which builds the
  11. ;; script from the lines it gets.  Note first the use of the match
  12. ;; negation character ("~") to discard the current directory and C:.
  13. ;; Each line in the main body is simply "path <directory-name>".
  14. ;; Preceding the main body are two lines (generated by a single label)
  15. ;; "failat 25" and "path reset"; at the end another label generates
  16. ;; "failat 10".
  17.  
  18.